package kr.hkit.powerjava.chapter11.work;

public class Book {

	String title;
	String page;
	String author;
	public Book(String title, String page, String author) {
		this.title = title;
		this.page = page;
		this.author = author;
		
		
	}
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	public String getPage() {
		return page;
	}
	public void setPage(String page) {
		this.page = page;
	}
	public String getAuthor() {
		return author;
	}
	public void setAuthor(String author) {
		this.author = author;
	}
	@Override
	public String toString() {
		return "Book [title=" + title + ", page=" + page + ", author=" + author
				+ "]";
	}
	
	
}

class Magazine extends Book {
	String felling;

	public Magazine(String title, String page, String author, String felling) {
		super(title, page, author);
		this.felling = felling;
	}

	public String getFelling() {
		return felling;
	}

	public void setFelling(String felling) {
		this.felling = felling;
	}

	@Override
	public String toString() {
		return "제목 : " + title + " , 페이지 수 : " + page + " , 저자 : "
				+ author + " , 발매일 : " + getFelling();
	}
	
	
}

